﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace Mvc4Learn.Models.Enum
{
    public enum Roles
    {
        Admin,
        PowerManager,
        User,
        Guest
    }

    public class RolesManager
    {
        public static List<Roles> GetRoles(string userName)
        {
            switch (userName)
            {
                case "admin":
                    return new List<Roles> {Roles.Admin, Roles.PowerManager};
                case "gqq":
                    return new List<Roles> {Roles.Admin};
                default:
                    return new List<Roles> {Roles.Guest};
            }
        }

    }
}